import {CHANGE_USER_NAME}from '../actions/user'
const initState = {
    name: '万佳鑫',
    age: 48,
    gender: '男'
}

//默认模块导出判断action.type，并且返回state
export default (state = initState, action) => {
    switch (action.type) {
        case CHANGE_USER_NAME:
        return{
            ...state,
            name:Math.random()
        }
        default:
            return state
    }
}